/*
    百分比换算管道
    接收数字，返回百分比字符串
*/
import { Pipe, PipeTransform } from '@angular/core';

@Pipe({name: 'per'})
export class PercentagePipe implements PipeTransform {

  transform(key: number, enums: any): string {
    let per = '';
    if (key) {
        key = key - 0;
        per = key * 100 + '%';
    }
    return per;
  }

}
